feat(message): deliver bounded inbox bodies - #239
Draft
schickling wants to merge 1 commit into
Draft
Conversation
This was referenced Aug 11, 2026
This was referenced Aug 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
st2.inbox-delivery.v1FIFO prefix with complete bodies, capped at 16 messages and 16 KiBst2 message deliveryview for hook and generic-fallback useWhy this shape
Issue #238 initially explored a batch settlement protocol. The reproduction and small-state prototype showed that bounded body delivery alone reduces the normal path from two model inferences/four model-tool crossings to one inference/two crossings. A settle/CAS/claim/journal design adds state and operations without improving that metric.
This change therefore adds no claim, lease, cursor, journal, disposition, automatic archive, or new durable state.
Contract and driver boundary
The durable inbox remains authoritative. The renderer selects a complete FIFO prefix; bodies are never truncated. Oversized heads receive an explicit metadata fallback, while overflow and post-batch arrivals remain unread.
The schema, bounds, selection, and tests are provider-neutral. The current Codex and Claude consumers are deliberately thin so issue #162 can transplant them into provider drivers without changing the contract. Unknown/custom providers retain the short metadata DING.
This PR is stacked on #237 at exact base
1d06c4b263a7c5a2a6b8eec1f2e8c4fbea5e2edcand reuses that typed Codex delivery receipt. It does not duplicate the Claude channel work in #232.End-to-end provider evidence
Companion eval PR: compoundingtech/evals#74 at exact head
0e6b64ebdc652687926d43f4a41a955831ddd846.Tracked receipt: https://github.com/compoundingtech/evals/blob/0e6b64ebdc652687926d43f4a41a955831ddd846/evidence/inbox-one-turn-provider-ab-runs-20260811.json
The baseline was body-blind: Claude explicitly discovered bodies, while Codex archived all messages but could only acknowledge subject-derived summaries. The candidate replied on and archived every hidden exact body, including a bounded burst and post-batch arrival.
The original provider executions completed but their judge launcher exited 127 due a cell-relative path. The eval receipt preserves that no-verdict axis and records deterministic RED/GREEN regrades of both preserved catalogs with the corrected graders; it does not relabel the original judge invocation as green.
Verification
At exact head
c1a0f90dd4814ec3ce8067219530d7bd8723e191:check: PASS (293 workspace library tests plus repository gates)cargo test --test invariants: 1 passedcargo test --test hooks --test codex_app_server: 14 passedcargo test --test claude_hooks --test message_cli: 14 passedcargo test --test native_only clean_path_executes_the_maintained_native_authoring_guide: passedgit diff --checkStrict Clippy reaches eight pre-existing warnings in unchanged files (
too_many_arguments,needless_borrow, andlet_and_return); no changed-file lint was reported before that baseline failure. Two unrelatednative_onlycases are environment/baseline red because/bin/sleepis absent and currentdocs/vrs/spec.mdalready contains the retired-name scan token; the changed native materialization case passes.Documentation authority
The active spec records the bounded view. Protected root
docs/vrs/requirements.mdis intentionally unchanged pending Nathan's explicit approval.Closes #238 when the stack is accepted. This PR remains draft pending review; do not merge or deploy from a focused branch.